Skip to content

fix: send property date values in UTC - #372

Merged
marandaneto merged 2 commits into
mainfrom
fix/utc-property-dates
Nov 24, 2026
Merged

marandaneto merged 2 commits into
mainfrom
fix/utc-property-dates

Conversation

@marandaneto

@marandaneto marandaneto commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

💡 Motivation and Context

Every RSpec and Logs integration job in CI prints this once, and customers on Rails 7.x see it in their own logs:

DEPRECATION WARNING: to_time will always preserve the timezone offset of the receiver in Rails 8.0. To opt in to the new behavior, set `ActiveSupport.to_time_preserves_timezone = true`. (called from PostHog::Utils#datetime_in_iso8601 at lib/posthog/utils.rb:75)

PostHog::Utils.datetime_in_iso8601 converted DateTime with datetime.to_time, which ActiveSupport overrides. The string therefore depended on the Rails version, to_time_preserves_timezone and the server's TZ, and Rails 8 would change it silently.

The helper now writes every date-time type as UTC with a Z suffix:

  • DateTime: formatted directly with new_offset(0).strftime('%Y-%m-%dT%H:%M:%S.%LZ'), without to_time.
  • Time and ActiveSupport::TimeWithZone: time_in_iso8601(value.getutc), the path the envelope timestamp already uses.
  • Date: unchanged (%F).
  • Still exactly 3 fractional digits, truncated rather than rounded.

The helper is kept because without it JSON encoding decides the format ("2026-11-23 10:30:15 +0530" in plain Ruby, which isn't ISO 8601, and app-dependent with ActiveSupport). The SDK doesn't set ActiveSupport.to_time_preserves_timezone, because that setting applies to the whole app.

Before / after

DateTime.new(2026, 11, 23, 10, 30, 15.123456r, '+05:30') with ActiveSupport 7.2. All rows are the same moment:

Environment Before After
Plain Ruby, no ActiveSupport 2026-11-23T10:30:15.123+05:30 2026-11-23T05:00:15.123Z
Rails 7.2 default, TZ=UTC 2026-11-23T05:00:15.123+00:00 plus the warning 2026-11-23T05:00:15.123Z
Rails 7.2 default, TZ=America/New_York 2026-11-23T00:00:15.123-05:00 plus the warning 2026-11-23T05:00:15.123Z
to_time_preserves_timezone = :zone, or Rails 8 2026-11-23T10:30:15.123+05:30 2026-11-23T05:00:15.123Z

Time and TimeWithZone values used to keep the caller's offset (10:30:15.123+05:30); they now also come out as 05:00:15.123Z.

Customer-visible effect

The moment in time stays the same, but the string changes. A Time property sent as ...+05:30 today now arrives as ...Z. This affects capture, identify and group identify properties and transactional email template_data. PostHog parses both forms, so filters and breakdowns behave the same. Anything that uses the raw string sees a different value: a before_send hook or downstream export that compares it, or an email template that prints the variable without formatting it (for example {{ variables.renews_at }}). This ships as a patch with a changeset that says so.

Spec

capture/spec.md (step 5 and "Timestamps on capture v1") requires the event envelope timestamp to be ISO 8601 and normalized to UTC. The spec does not say how date values inside properties are formatted. This change makes property dates follow the envelope rule and posthog-js (toISOString() is always UTC); no spec requires it. Microsecond precision, which the compliance report flags separately, is out of scope and stays truncated to 3 digits.

💚 How did you test it?

  • New spec/posthog/utils_spec.rb coverage: a non-UTC DateTime (UTC + Z, 3 truncated digits), non-UTC Time and TimeWithZone, UTC DateTime/Time, Date unchanged. Subprocess runs with TZ set to UTC, America/New_York and Asia/Tokyo, with and without ActiveSupport, assert the same output and no DEPRECATION WARNING on stderr. All six new examples failed on main before the fix.
  • Updated client_spec.rb "does not normalize arbitrary Time properties to UTC" (added in fix: normalize SDK timestamps to UTC #248 to keep that PR's scope to the envelope) to expect the UTC form.
  • bundle exec rspec (2595 examples, 0 failures, 49 pending; the output no longer contains the to_time warning), bundle exec rubocop, bundle exec rake public_api:check.

📝 Checklist

  • All commits are signed (see Commit signing)
  • I reviewed the submitted code.
  • I added tests to verify the changes.
  • I updated the docs if needed.
  • No breaking change or entry added to the changelog.

If releasing new changes

  • Ran pnpm changeset to generate a changeset file

🤖 Agent context

Autonomy: Human-driven (agent-assisted)

  • Pi coding agent (Claude). The maintainer chose the approach (UTC with Z for every date-time type, keep the helper, don't touch to_time_preserves_timezone). The agent wrote failing specs first, then implemented the fix.
  • Changing the fix: normalize SDK timestamps to UTC #248 spec that asserted property offsets were kept was deliberate: fix: normalize SDK timestamps to UTC #248 left properties alone only to limit its own scope.

@marandaneto marandaneto self-assigned this Nov 23, 2026
@github-actions

github-actions Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

posthog-ruby-sync Compliance Report

Date: 2026-11-24T15:46:22.420905+00:00
Duration: 94657ms

✅ All Tests Passed!

47/47 tests passed


Capture Tests

✅ 30/30 tests passed

View Details
Test Status Duration
Format Validation.Event Has Required Fields ✅ 10ms
Format Validation.Event Has Uuid ✅ 7ms
Format Validation.Event Has Lib Properties ✅ 7ms
Format Validation.Distinct Id Is String ✅ 9ms
Format Validation.Token Is Present ✅ 8ms
Format Validation.Custom Properties Preserved ✅ 8ms
Format Validation.Event Has Timestamp ✅ 9ms
Format Validation.Non Utc Event Timestamp Is Converted To Utc ✅ 7ms
Retry Behavior.Retries On 503 ✅ 5363ms
Retry Behavior.Does Not Retry On 400 ✅ 2010ms
Retry Behavior.Does Not Retry On 401 ✅ 2012ms
Retry Behavior.Respects Retry After Header ✅ 8018ms
Retry Behavior.Implements Backoff ✅ 15368ms
Retry Behavior.Retries On 500 ✅ 5117ms
Retry Behavior.Retries On 502 ✅ 5154ms
Retry Behavior.Retries On 504 ✅ 5121ms
Retry Behavior.Max Retries Respected ✅ 15694ms
Deduplication.Generates Unique Uuids ✅ 28ms
Deduplication.Preserves Uuid On Retry ✅ 5143ms
Deduplication.Preserves Uuid And Timestamp On Retry ✅ 10242ms
Deduplication.Preserves Uuid And Timestamp On Batch Retry ✅ 5121ms
Deduplication.No Duplicate Events In Batch ✅ 22ms
Deduplication.Different Events Have Different Uuids ✅ 12ms
Compression.Sends Gzip When Enabled ✅ 7ms
Batch Format.Uses Proper Batch Structure ✅ 7ms
Batch Format.Flush With No Events Sends Nothing ✅ 4ms
Batch Format.Synchronous Capture Delivers Each Event Immediately ✅ 20ms
Error Handling.Does Not Retry On 403 ✅ 2009ms
Error Handling.Does Not Retry On 413 ✅ 2011ms
Error Handling.Retries On 408 ✅ 5115ms

Feature_Flags Tests

✅ 17/17 tests passed

View Details
Test Status Duration
Request Payload.Request With Person Properties Device Id ✅ 13ms
Request Payload.Flags Request Uses V2 Query Param ✅ 11ms
Request Payload.Flags Request Hits Flags Path Not Decide ✅ 12ms
Request Payload.Flags Request Omits Authorization Header ✅ 11ms
Request Payload.Token In Flags Body Matches Init ✅ 9ms
Request Payload.Groups Round Trip ✅ 9ms
Request Payload.Groups Default To Empty Object ✅ 9ms
Request Payload.Disable Geoip False Propagates As Geoip Disable False ✅ 8ms
Request Payload.Disable Geoip Omitted Defaults To False ✅ 9ms
Request Payload.Flag Keys To Evaluate Contains Only Requested Key ✅ 9ms
Request Lifecycle.No Flags Request On Init Alone ✅ 3ms
Request Lifecycle.No Flags Request On Normal Capture ✅ 8ms
Request Lifecycle.Two Flag Calls Produce Two Remote Requests ✅ 12ms
Request Lifecycle.Mock Response Value Is Returned To Caller ✅ 8ms
Retry Behavior.Retries Flags On 502 ✅ 144ms
Retry Behavior.Retries Flags On 504 ✅ 115ms
Side Effect Events.Get Feature Flag Captures Feature Flag Called Event ✅ 11ms

@github-actions

github-actions Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

posthog-ruby-async Compliance Report

Date: 2026-11-24T15:46:16.590395+00:00
Duration: 98794ms

✅ All Tests Passed!

47/47 tests passed


Capture Tests

✅ 30/30 tests passed

View Details
Test Status Duration
Format Validation.Event Has Required Fields ✅ 109ms
Format Validation.Event Has Uuid ✅ 107ms
Format Validation.Event Has Lib Properties ✅ 109ms
Format Validation.Distinct Id Is String ✅ 106ms
Format Validation.Token Is Present ✅ 108ms
Format Validation.Custom Properties Preserved ✅ 108ms
Format Validation.Event Has Timestamp ✅ 108ms
Format Validation.Non Utc Event Timestamp Is Converted To Utc ✅ 7ms
Retry Behavior.Retries On 503 ✅ 5311ms
Retry Behavior.Does Not Retry On 400 ✅ 2110ms
Retry Behavior.Does Not Retry On 401 ✅ 2109ms
Retry Behavior.Respects Retry After Header ✅ 8117ms
Retry Behavior.Implements Backoff ✅ 15610ms
Retry Behavior.Retries On 500 ✅ 5214ms
Retry Behavior.Retries On 502 ✅ 5209ms
Retry Behavior.Retries On 504 ✅ 5214ms
Retry Behavior.Max Retries Respected ✅ 15518ms
Deduplication.Generates Unique Uuids ✅ 112ms
Deduplication.Preserves Uuid On Retry ✅ 5211ms
Deduplication.Preserves Uuid And Timestamp On Retry ✅ 10417ms
Deduplication.Preserves Uuid And Timestamp On Batch Retry ✅ 5215ms
Deduplication.No Duplicate Events In Batch ✅ 112ms
Deduplication.Different Events Have Different Uuids ✅ 108ms
Compression.Sends Gzip When Enabled ✅ 106ms
Batch Format.Uses Proper Batch Structure ✅ 107ms
Batch Format.Flush With No Events Sends Nothing ✅ 5ms
Batch Format.Multiple Events Batched Together ✅ 112ms
Error Handling.Does Not Retry On 403 ✅ 2110ms
Error Handling.Does Not Retry On 413 ✅ 2110ms
Error Handling.Retries On 408 ✅ 5214ms

Feature_Flags Tests

✅ 17/17 tests passed

View Details
Test Status Duration
Request Payload.Request With Person Properties Device Id ✅ 108ms
Request Payload.Flags Request Uses V2 Query Param ✅ 107ms
Request Payload.Flags Request Hits Flags Path Not Decide ✅ 107ms
Request Payload.Flags Request Omits Authorization Header ✅ 108ms
Request Payload.Token In Flags Body Matches Init ✅ 107ms
Request Payload.Groups Round Trip ✅ 108ms
Request Payload.Groups Default To Empty Object ✅ 107ms
Request Payload.Disable Geoip False Propagates As Geoip Disable False ✅ 109ms
Request Payload.Disable Geoip Omitted Defaults To False ✅ 107ms
Request Payload.Flag Keys To Evaluate Contains Only Requested Key ✅ 108ms
Request Lifecycle.No Flags Request On Init Alone ✅ 3ms
Request Lifecycle.No Flags Request On Normal Capture ✅ 106ms
Request Lifecycle.Two Flag Calls Produce Two Remote Requests ✅ 111ms
Request Lifecycle.Mock Response Value Is Returned To Caller ✅ 107ms
Retry Behavior.Retries Flags On 502 ✅ 259ms
Retry Behavior.Retries Flags On 504 ✅ 245ms
Side Effect Events.Get Feature Flag Captures Feature Flag Called Event ✅ 112ms

@marandaneto
marandaneto marked this pull request as ready for review November 23, 2026 19:28
@marandaneto
marandaneto requested a review from a team as a code owner November 23, 2026 19:28
@veria-ai

veria-ai Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

PR overview

No security issues were found in this pull request.

Reviews

@github-actions

Copy link
Copy Markdown

SDK performance: posthog-ruby

Benchmarks completed. No changes flagged for review.

Flags require at least a 5% change in the median and all six pairs agreeing on direction. This is a noise filter, not proof of a performance change or a CI gate.

View all results
Test Measurement Before PR With PR Change Assessment
Capture and deliver events (32-byte payload, burst)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Capture and deliver events (32-byte payload, steady)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Queue an event (32-byte payload)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​; head:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​
Queue an event (32-byte payload)
Shard: capture
Allocations per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​; head:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​
Queue an event (4,096-byte payload)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​; head:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​
Queue an event (4,096-byte payload)
Shard: capture
Allocations per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​; head:​ Background serialization has no public enqueue completion boundary; use completed-delivery workloads for process-wide allocation counts.​
Evaluate all 10 flags
Shard: flags-scaling
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate all 100 flags
Shard: flags-scaling
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate all 1,000 flags
Shard: flags-scaling
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate one boolean flag
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a cohort-filtered flag
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a flag (early match)
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a flag (late match)
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a flag (no match)
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a property-filtered flag
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a regex-filtered flag
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a rollout flag
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Evaluate a multivariate flag
Shard: flags-single
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​; head:​ Ruby has no cumulative allocated-byte counter here; retained ObjectSpace bytes are not allocation volume.​
Capture and deliver events (32-byte payload, burst)
Shard: capture
Allocations per operation 56.27 count/op 56.27 count/op No observed change Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Time per operation 108.87 µs/op 108.84 µs/op <0.1% less time Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Idle process memory (RSS) 28.41 MiB 28.4 MiB <0.1% less memory Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Observed peak process memory (RSS) 31.19 MiB 31.18 MiB <0.1% less memory Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Managed heap after settling 5.3 MiB 5.3 MiB <0.1% less memory Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Process memory after settling (RSS) 31.19 MiB 31.18 MiB <0.1% less memory Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Process CPU time per operation 19.95 µs/op 19.77 µs/op 0.9% less time Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Lifetime peak process memory (RSS) 31.31 MiB 31.31 MiB <0.1% less memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Allocations per operation 58.65 count/op 58.65 count/op No observed change Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Time per operation 108.81 µs/op 108.86 µs/op <0.1% more time Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Idle process memory (RSS) 33.25 MiB 33.23 MiB <0.1% less memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Observed peak process memory (RSS) 42.1 MiB 42.28 MiB 0.4% more memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Managed heap after settling 9.17 MiB 9.17 MiB <0.1% less memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Process memory after settling (RSS) 39.93 MiB 39.47 MiB 1.2% less memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Process CPU time per operation 27.69 µs/op 27.81 µs/op 0.4% more time Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Lifetime peak process memory (RSS) 41.92 MiB 42.07 MiB 0.4% more memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Allocations per operation 58.68 count/op 58.68 count/op No observed change Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Time per operation 1.02 ms/op 1.02 ms/op <0.1% less time Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Idle process memory (RSS) 28.34 MiB 28.3 MiB 0.1% less memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Observed peak process memory (RSS) 30.48 MiB 30.45 MiB <0.1% less memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Managed heap after settling 5.3 MiB 5.3 MiB <0.1% less memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Process memory after settling (RSS) 30.48 MiB 30.45 MiB <0.1% less memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Process CPU time per operation 31.75 µs/op 31.68 µs/op 0.2% less time Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Lifetime peak process memory (RSS) 30.48 MiB 30.45 MiB <0.1% less memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Allocations per operation 58.68 count/op 58.68 count/op No observed change Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Time per operation 1.01 ms/op 1.01 ms/op <0.1% less time Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Idle process memory (RSS) 33.24 MiB 33.28 MiB <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Observed peak process memory (RSS) 40.93 MiB 40.98 MiB 0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Managed heap after settling 9.17 MiB 9.17 MiB <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Process memory after settling (RSS) 39.38 MiB 40.98 MiB 4.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Process CPU time per operation 37.85 µs/op 37.07 µs/op 2.1% less time Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Lifetime peak process memory (RSS) 41.23 MiB 41 MiB 0.6% less memory Not flagged
Queue an event (32-byte payload)
Shard: capture
Caller-thread CPU time per operation 8.63 µs/op 8.69 µs/op 0.6% more time Not flagged
Queue an event (32-byte payload)
Shard: capture
Time per operation 8.63 µs/op 8.68 µs/op 0.6% more time Not flagged
Queue an event (4,096-byte payload)
Shard: capture
Caller-thread CPU time per operation 8.49 µs/op 8.55 µs/op 0.7% more time Not flagged
Queue an event (4,096-byte payload)
Shard: capture
Time per operation 8.48 µs/op 8.54 µs/op 0.7% more time Not flagged
Evaluate all 10 flags
Shard: flags-scaling
Allocations per operation 343.02 count/op 343.02 count/op No observed change Not flagged
Evaluate all 10 flags
Shard: flags-scaling
Time per operation 107.64 µs/op 109.2 µs/op 1.4% more time Not flagged
Evaluate all 10 flags
Shard: flags-scaling
Process CPU time per operation 107.63 µs/op 109.18 µs/op 1.4% more time Not flagged
Evaluate all 100 flags
Shard: flags-scaling
Allocations per operation 3,324 count/op 3,324 count/op No observed change Not flagged
Evaluate all 100 flags
Shard: flags-scaling
Time per operation 1.04 ms/op 1.04 ms/op 0.2% more time Not flagged
Evaluate all 100 flags
Shard: flags-scaling
Process CPU time per operation 1.04 ms/op 1.04 ms/op 0.2% more time Not flagged
Evaluate all 1,000 flags
Shard: flags-scaling
Allocations per operation 33,113.59 count/op 33,113.62 count/op <0.1% more Not flagged
Evaluate all 1,000 flags
Shard: flags-scaling
Time per operation 11.99 ms/op 11.96 ms/op 0.3% less time Not flagged
Evaluate all 1,000 flags
Shard: flags-scaling
Process CPU time per operation 11.99 ms/op 11.96 ms/op 0.3% less time Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Idle process memory (RSS) 39.09 MiB 39.12 MiB <0.1% more memory Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Observed peak process memory (RSS) 40.31 MiB 40.4 MiB 0.2% more memory Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Managed heap after settling 7.99 MiB 7.99 MiB <0.1% more memory Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Process memory after settling (RSS) 39.41 MiB 39.5 MiB 0.2% more memory Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Lifetime peak process memory (RSS) 40.04 MiB 40.1 MiB 0.2% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Idle process memory (RSS) 38.01 MiB 38.04 MiB <0.1% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Observed peak process memory (RSS) 42.23 MiB 42.24 MiB <0.1% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Managed heap after settling 9.5 MiB 9.5 MiB <0.1% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Process memory after settling (RSS) 41.35 MiB 41.37 MiB <0.1% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Lifetime peak process memory (RSS) 41.98 MiB 42.05 MiB 0.2% more memory Not flagged
Evaluate one boolean flag
Shard: flags-single
Allocations per operation 38 count/op 38 count/op No observed change Not flagged
Evaluate one boolean flag
Shard: flags-single
Time per operation 7.87 µs/op 7.88 µs/op <0.1% more time Not flagged
Evaluate one boolean flag
Shard: flags-single
Process CPU time per operation 7.87 µs/op 7.88 µs/op <0.1% more time Not flagged
Evaluate a cohort-filtered flag
Shard: flags-single
Allocations per operation 38 count/op 38 count/op No observed change Not flagged
Evaluate a cohort-filtered flag
Shard: flags-single
Time per operation 10.49 µs/op 10.56 µs/op 0.7% more time Not flagged
Evaluate a cohort-filtered flag
Shard: flags-single
Process CPU time per operation 10.49 µs/op 10.56 µs/op 0.7% more time Not flagged
Evaluate a flag (early match)
Shard: flags-single
Allocations per operation 55 count/op 55 count/op No observed change Not flagged
Evaluate a flag (early match)
Shard: flags-single
Time per operation 13.5 µs/op 13.53 µs/op 0.2% more time Not flagged
Evaluate a flag (early match)
Shard: flags-single
Process CPU time per operation 13.5 µs/op 13.53 µs/op 0.2% more time Not flagged
Evaluate a flag (late match)
Shard: flags-single
Allocations per operation 76 count/op 76 count/op No observed change Not flagged
Evaluate a flag (late match)
Shard: flags-single
Time per operation 19.11 µs/op 18.95 µs/op 0.8% less time Not flagged
Evaluate a flag (late match)
Shard: flags-single
Process CPU time per operation 19.11 µs/op 18.95 µs/op 0.8% less time Not flagged
Evaluate a flag (no match)
Shard: flags-single
Allocations per operation 67 count/op 67 count/op No observed change Not flagged
Evaluate a flag (no match)
Shard: flags-single
Time per operation 17 µs/op 17.08 µs/op 0.5% more time Not flagged
Evaluate a flag (no match)
Shard: flags-single
Process CPU time per operation 17 µs/op 17.08 µs/op 0.5% more time Not flagged
Evaluate a property-filtered flag
Shard: flags-single
Allocations per operation 34 count/op 34 count/op No observed change Not flagged
Evaluate a property-filtered flag
Shard: flags-single
Time per operation 8.05 µs/op 8.03 µs/op 0.2% less time Not flagged
Evaluate a property-filtered flag
Shard: flags-single
Process CPU time per operation 8.05 µs/op 8.03 µs/op 0.2% less time Not flagged
Evaluate a regex-filtered flag
Shard: flags-single
Allocations per operation 99 count/op 99 count/op No observed change Not flagged
Evaluate a regex-filtered flag
Shard: flags-single
Time per operation 23.02 µs/op 22.95 µs/op 0.3% less time Not flagged
Evaluate a regex-filtered flag
Shard: flags-single
Process CPU time per operation 23.02 µs/op 22.95 µs/op 0.3% less time Not flagged
Evaluate a rollout flag
Shard: flags-single
Allocations per operation 31 count/op 31 count/op No observed change Not flagged
Evaluate a rollout flag
Shard: flags-single
Time per operation 7.06 µs/op 7.09 µs/op 0.4% more time Not flagged
Evaluate a rollout flag
Shard: flags-single
Process CPU time per operation 7.06 µs/op 7.09 µs/op 0.4% more time Not flagged
Evaluate a multivariate flag
Shard: flags-single
Allocations per operation 37 count/op 37 count/op No observed change Not flagged
Evaluate a multivariate flag
Shard: flags-single
Time per operation 8.85 µs/op 8.8 µs/op 0.5% less time Not flagged
Evaluate a multivariate flag
Shard: flags-single
Process CPU time per operation 8.85 µs/op 8.81 µs/op 0.5% less time Not flagged

Values are medians of paired measurements. Not flagged does not mean unchanged. Unavailable means a measurement could not be provided, not zero. Estimated allocation measurements retain their instrumentation uncertainty. RSS measures the whole process, not just SDK allocations; observed peaks are sampled checkpoints. Paired ranges in the diagnostics describe variability, not confidence intervals.

Each shard uses its own runner; compare Before PR against With PR within a row, not across shards.

Compared 579b3fbf0ecb3a85f0de94f1754448b62613b0e7 → 62a0c7baa39c1c3df053277223e797323e7ca0a6.

Full report and diagnostics

102 metric rows; 102 rows shown in all results. Omitted or shortened data remain in comparison.json, including per-runner environments, resource limits, measurement methods, samples and checkpoints.

@dustinbyrne dustinbyrne left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me — cleanly removes the Rails 7.x/8.0 DateTime#to_time deprecation warning and TZ-dependent formatting while keeping Time, ActiveSupport::TimeWithZone, and DateTime consistent in UTC Z with 3 truncated fractional digits. Verified locally across plain Ruby and ActiveSupport 7.2 / 8.0 / 8.1 and checked backend property-defs-rs + HogQL parsing.

Left one minor wording suggestion on the changeset for rendered email templates.

AI-assisted review.

Comment thread .changeset/utc-property-dates.md Resolved
@marandaneto
marandaneto merged commit b1135df into main Nov 24, 2026
29 of 30 checks passed
@marandaneto
marandaneto deleted the fix/utc-property-dates branch November 24, 2026 15:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants